package cn.stylefeng.guns.modular.customer.entity;

import java.math.BigDecimal;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import java.util.Date;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.TableField;
import lombok.Data;

import java.io.Serializable;

/**
 * <p>
 * 用户表
 * </p>
 *
 * @author typ
 * @since 2021-04-25
 */
@TableName("yy_customer")
@Data
public class Customer implements Serializable {

    private static final long serialVersionUID=1L;

      @TableId(value = "id", type = IdType.ID_WORKER)
    private Integer id;

    @TableField("mobile")
    private String mobile;

    @TableField("password")
    private String password;

    @TableField("avatar")
    private String avatar;

      @TableField(value = "create_time", fill = FieldFill.INSERT)
    private Date createTime;

      @TableField(value = "update_time", fill = FieldFill.UPDATE)
    private Date updateTime;

    @TableField("realname")
    private String realname;

    @TableField("sex")
    private Integer sex;

    /**
     * 1学员 2社长
     */
    @TableField("role")
    private Integer role;

    /**
     * 父级id
     */
    @TableField("pid")
    private Integer pid;

    /**
     * 父级的父级id
     */
    @TableField("grand_id")
    private Integer grandId;

    /**
     * 帮扶领导
     */
    @TableField("leader")
    private Integer leader;

    /**
     * 昵称
     */
    @TableField("nickname")
    private String nickname;

    /**
     * 余额
     */
    @TableField("money")
    private BigDecimal money;

    @TableField("openid")
    private String openid;




    @Override
    public String toString() {
        return "Customer{" +
        "id=" + id +
        ", mobile=" + mobile +
        ", password=" + password +
        ", avatar=" + avatar +
        ", createTime=" + createTime +
        ", updateTime=" + updateTime +
        ", realname=" + realname +
        ", sex=" + sex +
        ", role=" + role +
        ", pid=" + pid +
        ", grandId=" + grandId +
        ", leader=" + leader +
        ", nickname=" + nickname +
        ", money=" + money +
        "}";
    }
}
